<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
        <script src="https://g.alicdn.com/jssdk/u-link/index.min.js"></script>
    </head>

<body>
<a id="aLink" href="aobogame://umeng.com/wanpai">没有自动跳转点击这里</a>
<script type="text/javascript">
    var u = navigator.userAgent;
    var params = ULink.getUriDecodeParams() || {}
    var roomid = params.roomid || 0
    var isAndroid = u.indexOf('Android') > -1 || u.indexOf('Adr') > -1; //android终端
    var isiOS = !!u.match(/\(i[^;]+;( U;)? CPU.+Mac OS X/); //ios终端
    if (isAndroid) {
        document.getElementById("aLink").setAttribute('href', "aobogame://umeng.com/wanpai?roomid="+roomid);
        window.location.href = "aobogame://umeng.com/wanpai?roomid="+roomid
    } else if (isiOS) {
        document.getElementById("aLink").setAttribute('href', "aobogame://umeng.com/wanpai?roomid="+roomid);
        window.location = "aobogame://umeng.com/wanpai?roomid="+roomid
    }
    // ULink.start({
    //     id: 'usr192s60ih7f5i4', /* 平台为每个应用分配的方案link ID，必填 */
    //     data: {
    //         roomid:roomid,
    //         game:"sss"
    //     } /* 自定义参数，选填 */
    // }).ready(function(ctx) { /* 初始化完成的回调函数 */
    //     ctx.wakeup(); /* 页面加载后即启动app */
    // });
</script> 
</body>

</html>